package com.yidu.DailyFinalTreatment.service.impl;

import com.yidu.DailyFinalTreatment.entity.OperationNetWorth;
import com.yidu.DailyFinalTreatment.mapper.OperationNetWorthMapper;
import com.yidu.DailyFinalTreatment.service.OperationNetWorthService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class OperationNetWorthServiceImpl implements OperationNetWorthService {
    @Autowired
    protected OperationNetWorthMapper operationNetWorthMapper;

    @Override
    public List<OperationNetWorth> selectOpertionNetWorth(String dateTime, String fundId, int type) {
        List<OperationNetWorth> operationNetWorths = operationNetWorthMapper.selectOpertionNetWorth(dateTime, fundId, type);
        return operationNetWorths;
    }

    @Override
    public List<OperationNetWorth> selectOperationTA(String cashId, int type, int typeTwo, String dateTime, String fundId) {
        List<OperationNetWorth> operationNetWorthTA = operationNetWorthMapper.selectOperationTA(cashId, type, typeTwo, dateTime, fundId);
        return operationNetWorthTA;
    }

    @Override
    public List<OperationNetWorth> selectOperationCost(String cashId, String dateTime, String fundId, int type) {
        List<OperationNetWorth> operationNetWorthCost = operationNetWorthMapper.selectOperationCost(cashId, dateTime, fundId, type);
        return operationNetWorthCost;
    }
}
